import { ru } from 'date-fns/locale'
import { formatDate } from "date-fns";
export const HistoryItem = ({ userName, userImage, date, action }: TaskItemAction) => {
  return (
    <div className="flex items-center justify-between gap-2 p-2" >
      <div className="flex items-center gap-2" >
        <div className=' aspect-square size-[40px] rounded-full overflow-hidden flex justify-center items-center' >
          <img src={'https://u13-crm-test.gexarus.com' + userImage} alt="" />
        </div>
        <span className='text-[15px] text-[#37373B] ' >{userName}</span>
      </div>
      <p className='text-[14px] text-[#37373B]' >{action}</p>
      <span className='text-[14px] text-[#37373B]' >{formatDate(date, 'dd MMMM', { locale: ru })}</span>
    </div>
  )
}